package com.share.dubbo.es.service.impl;

import com.share.common.common.Page;
import com.share.common.common.Result;
import com.share.dubbo.es.manager.EsJavaLogManager;
import com.share.dubbo.es.model.EsJavaLogReq;
import com.share.dubbo.es.model.EsJavaLogResq;
import com.share.dubbo.es.model.EsJavaLogSaveReq;
import com.share.dubbo.es.service.EsJavaLogService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Slf4j
@Service
public class EsJavaLogServiceImpl implements EsJavaLogService {
    @Autowired
    private EsJavaLogManager esJavaLogManager;


    @Override
    public Result count(EsJavaLogReq req) {
        return Result.success(esJavaLogManager.count(req));
    }

    @Override
    public Result<Page<EsJavaLogResq>> pageList(EsJavaLogReq req) {
        return Result.success(esJavaLogManager.pageList(req));
    }

    @Override
    public Result<Long> save(EsJavaLogSaveReq req) {
        return Result.success(esJavaLogManager.save(req));
    }
}
